package com.adcc.soundalarm.config.regular;

import com.google.common.collect.Lists;

import java.util.List;

/**
 * Created by zhangdawei on 2017/3/8.
 */
public class BGSFactory {

    private String name;

    // 配置状态管理-多状态
    private List<String> state = Lists.newArrayListWithCapacity(4);

    // BGS 当前状态
    private String currentState;

    /**
     * 设置BGS状态
     * @param state
     */
    public void setState(String state){
        this.state.add(state);
    }

    public void setAllState(List<String> allState){
        this.state.clear();
        this.state.addAll(allState);
    }

    /**
     * 设置用户名
     * @param name
     */
    public void setName(String name) {
        this.name = name;
    }

    /**
     * 获取用户名
     * @return
     */
    public String getName() {
        return name;
    }

    /**
     * 获取BGS状态列表
     * @return
     */
    public List<String> getState() {
        return state;
    }

    /**
     * 清空队列
     */
    public void clearAllState(){
        this.state.clear();
    }

    public String getCurrentState() {
        return currentState;
    }

    public void setCurrentState(String currentState) {
        this.currentState = currentState;
    }
}
